home *** CD-ROM | disk | FTP | other *** search
/ BCI NET / BCI NET Dec 94.iso / archives / programming / c / gcc261ud-c.lha / gnu / os-include / inline / alib.h next >
C/C++ Source or Header  |  1994-09-06  |  655b  |  36 lines

  1. #ifndef _INLINE_ALIB_H
  2. #define _INLINE_ALIB_H
  3.  
  4. #include <sys/cdefs.h>
  5. #include <inline/stubs.h>
  6.  
  7. #include <exec/io.h>
  8.  
  9. __BEGIN_DECLS
  10.  
  11. extern __inline void
  12. BeginIO (struct IORequest *iorequest)
  13. {
  14.   register struct IORequest *a1 asm("a1")=iorequest;
  15.   register struct Device    *a6 asm("a6")=iorequest->io_Device;
  16.   __asm __volatile ("jsr a6@(-0x1e)"
  17.   : /* no output */
  18.   : "r" (a6), "r" (a1)
  19.   : "a0","a1","d0","d1","memory");
  20. }
  21.  
  22. extern __inline void
  23. NewList(struct List *list)
  24. {
  25.    LONG *p;
  26.  
  27.    list->lh_TailPred=(struct Node*)list;
  28.    ((LONG *)list)++;
  29.    *(LONG *)list=0;
  30.    p=(LONG *)list; *--p=(LONG)list;
  31. }
  32.  
  33. __END_DECLS
  34.  
  35. #endif /* _INLINE_ALIB_H */
  36.